package main

import "fmt"

/*
panic: runtime error: invalid memory address or nil pointer dereference
[signal 0xc0000005 code=0x1 addr=0x0 pc=0x7ff68dd0edb0]

goroutine 1 [running]:
main.main()

	D:/giteeWorks/go-stduy/七、Golang 指针/大地/demo05.go:8 +0x10
*/
func main() {

	/*	var a *int
	*a = 200
	fmt.Println(a)*/

	var a *int = new(int)
	*a = 200
	fmt.Println(a)

	var b = new(int)
	*b = 200
	fmt.Println(b)
}
